import React, { useEffect } from 'react'
import * as Cesium from 'cesium';
// import 'cesium/Build/Cesium/Widgets/widgets.css';


function Ces() {

    const MyCesiumComponent = () => {
        useEffect(() => {
            // const cesiumBaseurl = import.meta.env.CESIUM_BASE_URL;
            // Cesium.buildModuleUrl.setBaseUrl(cesiumBaseurl)

            const viewer = new Cesium.Viewer('cesiumContainer')
            return () => {
                viewer.destroy()
            }
        }, [])
        return <div id='cesiumContainer' style={{ width: '100%', height: '88%' }} />
    }
    return (
        <>
            <MyCesiumComponent />
        </>
    )
}

export default Ces